﻿using Sustainalytics.Entities;
using System;
using System.Collections.Generic;
using Ent = Sustainalytics.Entities;

namespace Sustainalytics.News.BusinessLogic
{
    public interface INewsManagement
    {
        List<Ent.News> GetNews(NewsFilter filter, Guid? accountId, int? skip, int? take, string[] orderBy = null, bool orderByAsc = true);

        int GetNewsCount(NewsFilter filter);

        Ent.News GetNews(Guid newsId, Guid? accountId);

        /// <summary>
        /// Get multiple news by IDs.
        /// </summary>
        /// <param name="newsIds"> News IDs. </param>
        /// <returns> News list. </returns>
        IEnumerable<Ent.News> GetNewsByIds(IEnumerable<Guid> newsIds);

        Ent.News AddNews(Ent.News news);

        Ent.News UpdateNews(Ent.News news);

        void DeleteNews(Guid newsId);

        void DeleteMultipleNews(IEnumerable<Guid> newsItems);

        void PublishMultipleNews(IEnumerable<Guid> newsItems);

        void PatchNews(NewsPatch patchData);
    }
}
